package com.hospital.register.statistics.controller;


import com.hospital.register.common.result.Result;
import com.hospital.register.dto.order.OrderDayDto;
import com.hospital.register.order.client.OrderFeignClient;
import com.hospital.register.vo.order.OrderDaysVo;
import io.swagger.annotations.ApiOperation;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController
@RequestMapping("/admin/statistics")
public class StatisticsController {

    @Autowired
    private OrderFeignClient orderFeignClient;

    @ApiOperation("获取预约统计数据")
    @GetMapping("/getCountMap")
    public Result getCountMap(OrderDayDto conditions) {
        OrderDaysVo countDate = orderFeignClient.getCountMap(conditions);
        return Result.ok(countDate);
    }

}
